import 'package:kkhousekeep/generated/json/base/json_convert_content.dart';
import 'package:kkhousekeep/models/login_owner_entity.dart';

LoginOwnerEntity $LoginOwnerEntityFromJson(Map<String, dynamic> json) {
	final LoginOwnerEntity loginOwnerEntity = LoginOwnerEntity();
	final int? code = jsonConvert.convert<int>(json['code']);
	if (code != null) {
		loginOwnerEntity.code = code;
	}
	final LoginOwnerObj? obj = jsonConvert.convert<LoginOwnerObj>(json['obj']);
	if (obj != null) {
		loginOwnerEntity.obj = obj;
	}
	final String? msg = jsonConvert.convert<String>(json['msg']);
	if (msg != null) {
		loginOwnerEntity.msg = msg;
	}
	return loginOwnerEntity;
}

Map<String, dynamic> $LoginOwnerEntityToJson(LoginOwnerEntity entity) {
	final Map<String, dynamic> data = <String, dynamic>{};
	data['code'] = entity.code;
	data['obj'] = entity.obj.toJson();
	data['msg'] = entity.msg;
	return data;
}

LoginOwnerObj $LoginOwnerObjFromJson(Map<String, dynamic> json) {
	final LoginOwnerObj loginOwnerObj = LoginOwnerObj();
	final String? token = jsonConvert.convert<String>(json['token']);
	if (token != null) {
		loginOwnerObj.token = token;
	}
	final bool? roomCheckPass = jsonConvert.convert<bool>(json['roomCheckPass']);
	if (roomCheckPass != null) {
		loginOwnerObj.roomCheckPass = roomCheckPass;
	}
	final String? ownerType = jsonConvert.convert<String>(json['ownerType']);
	if (ownerType != null) {
		loginOwnerObj.ownerType = ownerType;
	}
	final String? ownerName = jsonConvert.convert<String>(json['ownerName']);
	if (ownerName != null) {
		loginOwnerObj.ownerName = ownerName;
	}
	final String? ownerImage = jsonConvert.convert<String>(json['ownerImage']);
	if (ownerImage != null) {
		loginOwnerObj.ownerImage = ownerImage;
	}
	return loginOwnerObj;
}

Map<String, dynamic> $LoginOwnerObjToJson(LoginOwnerObj entity) {
	final Map<String, dynamic> data = <String, dynamic>{};
	data['token'] = entity.token;
	data['roomCheckPass'] = entity.roomCheckPass;
	data['ownerType'] = entity.ownerType;
	data['ownerName'] = entity.ownerName;
	data['ownerImage'] = entity.ownerImage;
	return data;
}